Text-only template For code
[show modes: view html edit info]
[begin mode view]
<pre style="word-wrap: break-word; white-space: pre-wrap; font-size: 10pt; font-family: Monaco;">
[replace(replace(replace($_body, "&", "&" & "amp;"), ">", ">"), "<", "<")]
</pre>
[end mode view]
[begin mode html]
[$_body]
[end mode html]
[begin mode abbr]
<li><a href="/?[$_title]">[$_title]</a>
[$children = children("abbr", $_id);
iif($children, echo("<ol>" & $children & "</ol>"), "");]
</li>
[end mode abbr]
[begin mode info]
<style type="text/css">
.tot_info th {
vertical-align: top;
}
</style>
<table class="tot_info">
<tr><th>Title:</th><td>[info_display($_title)]</td></tr>
<tr><th>Subtitle:</th><td>[info_display($_subtitle)]</td></tr>
<tr><th>Parent:</th><td>[$_parent; if($_parent > 0) { ([get_title($_parent);])}]</td></tr>
<tr><th>Permissions:</th><td>[$_permissions]</td></tr>
<tr><th>Author:</th><td>[$_author]</td></tr>
<tr><th>Group:</th><td>[$_group]</td></tr>
<tr><th>ID:</th><td>[$_id]</td></tr>
<tr><th>Date:</th><td>[$_date]</td></tr>
<tr><th>Priority:</th><td>[$_priority]</td></tr>
<tr><th>Template:</th><td>[$_template]</td></tr>
[if(get_executable($_id) == 3) {
<tr><th>Used by:</th><td><ul>[search("abbr", "template", $_id)]</ul></td>
};]
<tr><th>Body:</th><td><tt>[info_display($_body)]</tt></td></tr>
    </table>
[end mode info]
[begin mode edit]
    <form method="post" action="/" width="10)%">
        <input type="hidden" name="page" value="[$_title]">
        <input type="hidden" name="mode" value="submit">
<table width="100%">
        <tr><th>Title:</th><td><input type="text" class="textbox" name="title" value="[edit_display($_title)]" style="width: 100%"></td></tr>
        <tr><th>Subtitle:</th><td><input type="text" class="textbox" name="subtitle" value="[edit_display($_subtitle)]" style="width: 100%"></td></tr>
        <tr><th>Parent:</th><td><input type="text" class="textbox" name="parent" value="[$_parent]"></td></tr>
        <tr><th>Permissions:</th><td><input type="text" class="textbox" name="permissions" value="[$_permissions]"></td></tr>
        <tr><th>Author:</th><td><input type="text" class="textbox" name="author" value="[$_author]"></td></tr>
        <tr><th>Group:</th><td><input type="text" class="textbox" name="group" value="[$_group]"></td></tr>
        <tr><th>Priority:</th><td><input type="text" class="textbox" name="priority" value="[$_priority]"></td></tr>
        <tr><th>Template:</th><td><input type="text" class="textbox" name="template" value="[$_template]"></td></tr>
        <tr><th>Body:</th><td><textarea class="textbox" name="body" rows="40" cols="70" style="font-size: 11pt; font-family: Monaco, monospace;">[edit_display($_body)]</textarea></td></tr>
<tr><td></td><td>
        <span class="buttonbox"><input name="submitButton" class="submit" type="submit" value="Submit"></span> <i>your permissions</i>: [$_viewer.permissions]</td></tr></table>
    </form>
[end mode edit]
[begin mode select][$_id]<!>[$_title][end mode select]
[begin mode submit]
    [$_title = $_params.title]
    [$_subtitle = $_params.subtitle]
    [$_parent = $_params.parent]
    [$_permissions = $_params.permissions]
    [$_author = $_params.author]
    [$_group = $_params.group]
    [$_body = $_params.body]
    [$_priority = $_params.priority]
    [$_template = $_params.template]
    <h2>Page updated.</h2>
    <a href="/?[$_title]">Return to it.</a>
    <a href="/?id=[$_id]">(Or by ID.)</a><br>
    <a href="/?id=[$_id]&mode=edit">Edit it again.</a><br>
[end mode submit]